import java.util.Arrays;
import java.util.Scanner;

//TIP To <b>Run</b> code, press <shortcut actionId="Run"/> or
// click the <icon src="AllIcons.Actions.Execute"/> icon in the gutter.
public class Main {
    public static void merge(int[] A,int m,int[] B,int n){
        int a = m-1;
        int b = n-1;
        int c = m+n-1;
        while(a>=0 && b>=0){
            if(A[a] >= B[b]){
                A[c] = A[a];
                a--;
                c--;
            }else{
                A[c] = B[b];
                b--;
                c--;
            }
        }
        if(a < 0){
            for (int i = 0; i < b; i++) {
                A[i] = B[i];
            }
        }
        System.out.println(Arrays.toString(A));
    }
    public static void main(String[] args) {
        int[] A = new int[10];
        A[0] = 1;
        A[1] = 3;
        A[2] = 4;
        A[3] = 5;
        A[4] = 7;

        int[] B = {3,4,6,8,9};
        merge(A,5,B,5);


    }
    public static String func(String in){
        boolean[] flg = new boolean[127];
        StringBuffer str = new StringBuffer();
        for (int i = 0; i < in.length(); i++) {
            char ch = in.charAt(i);
            if(flg[ch] == false){
                flg[ch] = true;
                str.append(ch);
            }
        }
        return str.toString();

    }
    public static void main1(String[] args) {
        Scanner scan = new Scanner(System.in);
        while(scan.hasNextLine()){
            String in = scan.nextLine();
            System.out.println(func(in));
        }

    }
}